import com.alibaba.fastjson.JSONObject;

/**
 * @author gzkemays
 * @since 2022/6/29 21:52
 */
public class IconDomain {
  public static void main(String[] args) {
    String test = "{\\\"picMaxCount\\\":314}";
    System.out.println(JSONObject.parseObject(test));
    /*    String domain = "https://primefaces.org/abc/efg";
    String prefixDomain = domain.substring(domain.indexOf("://") + 3),
        prefixHttp = domain.substring(0, domain.indexOf("://") + 3);
    System.out.println(prefixDomain);
    System.out.println(prefixHttp);*/
    /*    YzjHttpResult send =
        YzjHttp.createGet(domain)
            .defaultUserAgent()
            .config(YzjSendConfig.start().document().end())
            .send();
    Document document = send.getDocument();
    List<String> links = new ArrayList<>();
    Elements headers = document.getElementsByTag("head");
    for (Element header : headers) {
      Elements children = header.children();
      for (Element child : children) {
        if (child.hasAttr("rel")) {
          String rel = child.attr("rel");
          String link;
          if (rel.contains("icon")) {
            if (StringUtils.isNotBlank(link = (child.attr("href")))) {
              if (link.startsWith("//")) {
                link = link.replaceFirst("//", "");
              } else if (link.startsWith("/")) {
                link = link.replaceFirst("/", "");
              }
              links.add(link);
            }
          }
        }
      }
    }
    System.out.println("links = " + links);*/
  }
}
